package com.kawa.kemanage.controller.app;

import com.kawa.kemanage.entity.Report;
import com.kawa.kemanage.service.ReportService;
import com.kawa.kemanage.util.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/app/violation") // 更新路径
public class ReportController {

    @Autowired
    private ReportService reportService;

    @PostMapping("/add")
    public Result<String> addReport(@RequestBody Report report) {
        return reportService.addReport(report);
    }
}




